package com.zhongan.common.enums;

/**
 * * @ClassName: ErrorCode
 *
 * @Description:TODO(常用公共返回接口状态Code)
 * @author: 余胜军
 * @date: 2017年4月20日 上午10:43:04
 */
public enum ErrorCode {


    UNKNOWN("-1", "服务器内部错误"),
    NORMAL("0", "成功"),
    NOT_ORGANIZATION("5","非此机构员工"),
    INVALID_TOKEN("1","您登录的账号已过期，请重新登录。"),
    DATE_FALSE("6","时间设定冲突"),
    ATTEND_CONFLICT("30","该考勤设定状态已存在"),
    DATE_BEGIN_END("31","开始时间应小于结束时间"),
    TOKEN_NOT_FOUND("11","您登录的账号已过期，请重新登录"),
    FAIL_SEND_SMS("2","手机验证码发送失败"),
    INVALID_SMS_CODE("3","您未获取手机验证码或您的手机验证码已经失效，请重新获取验证码。"),
    WRONG_SMS_CODE("4","手机验证码不正确"),
    NEED_LOGIN("8","您没有权限访问该模块,请先登录"),
    SIGN_ERROR("9", "验签失败"),
    COMMON("10", "服务器繁忙，请稍后再试！"),
    ACCOUNT_INPUT("50","请输入登录账户信息"),
    PASSWORD_INPUT("51","请输入登录密码"),
    ACCOUNT_NOT_EXIST("52","用户登录账号填写有误，请重新确认！"),
    MOBILE_REPEAT("53","该手机号已注册"),
    ACCOUNT_LOCK("54","由于您之前的异常操作，您的账户已经被锁定"),
    PASSWORD_CHECK_FAIL("55","登录密码错误，请重新确认！"),
    LOCK_24_HOURS("56","密码输错次数过多，账号被锁定24小时"),
    CERT_INFO_INPUT("57","请输入身份证信息"),
    CERTCODE_INVALID("58","身份证号码填写错误"),
    TRADE_PASSWORD_INPUT("59","请输入交易密码"),
    TRADE_PASSWORD_INVALID("60","交易密码填写错误"),
    EMAIL_BIND_NO_EXIST("61","绑定邮箱不存在"),
    EMAIL_VALICODE_DISABLE("62","邮箱验证码已失效"),
    EMAIL_VALICODE_INVALID("63","邮箱验证码填写错误"),
    EMAIL_VALICODE_INPUT("64","请输入邮箱验证码"),
    PASSWORD_FORMAT_INVALID("65","密码格式错误，需为数字"),
    STAFFNO_FORMAT_INVALID("66","工号格式错误，需为数字"),
    STAFFNO_LENGTH_INVALID("67","工号需为10位数字"),
    PASSWORD_LENGTH_INVALID("68","密码需为6~12位数字"),
    SAME_STAFFNO_AND_PASSWORD("69","工号和密码不可以相同"),
    FOUR_DIFF_NUM_PASSWORD("70","密码需包含4个以上不同数字"),
    CONTINUOUS_DIGIT("71","密码不能为连续6位数字"),
    INVALIDATED_USER("72","该账号已失效，请重新确认"),
    MOBILE_INPUT("100","请输入手机号码"),
    MOBILE_FORMAT_INVALID("101","手机号码格式错误"),
    SMS_CODE_INPUT("103","请输入您收到的短信验证码"),
    SMS_CODE_MUST_SIX("104","短信验证码必须为6位数字"),
    SMS_CODE_DISALBE("105","短信验证码已失效"),
    SMS_CODE_CHECK_FAIL("106","短信验证码错误"),
    SMS_CODE_CHECK_FAIL_TIMES("107","短信验证码输入错误，您还有%d次机会"),
    VERITY_CERT_STATUS_ERROR("108","用户身份验证流程状态错误"),
    LOCK_FOR_SMSCODE_FAIL("200","您的帐号短信验证码错误次数过多，帐号已被锁定"),
    FIRST_TIME_LOGIN("109","亲爱的营销伙伴：欢迎您登陆并使用横琴人寿移动营销系统。为保障您的账号安全，首次登录后请重新设置登录密码！"),
    STAFFNO_OR_PHONENO_WRONG("110","工号与手机号码不匹配，请重新确认!"),
    IMG_VALICODE_DISABLE("111","您输入的图片验证码已过期，请点击验证码重新获取"),
    MULTITERMINAL_LOGIN("112","您的账号已经在其他设备登录，请退出当前账号，重新登录。若非本人操作，请立即修改密码！"),
    RE_ENTRY("113","请重新登录"),
    /**客户中心相关**/
    AGENTID_IS_NULL("1000001","代理人Id为空！"),
    FIELDS_5_REPEAT("1000002","已经有相同五证信息的客户"),
    FIELDS_3_REPEAT("1000003","已存在相同姓名、性别、出生日期的客户，是否继续保存？"),
    NAME_AND_MOBILE_REPEAT("1000004","已有相同姓名与手机号的客户"),
    CUSTOMER_ADD_FAIL("1000005","新增客户记录失败！"),
    CUSTOMER_UPDATE_FAIL("1000006","更新客户记录失败！"),
    TRN_OBJ_FAIL("1000007","对象转换失败！"),
    CUSTOMERS_IS_EMPTY("1000008","传入的是空的客户信息"),
    SYSTEM_ERROR("10000", "系统异常"),
    BUSINESS_ERROR("10001", "业务异常"),
    INVALID_PARAM("10002","非法参数"),
    INVALID_TYPE("10003", "不支持的处理类型"),
    IMG_CODE_FAIL("10005", "图片验证码输入不正确，请重新确认！"),
    NOT_FOUND("10006", "没有数据"),
    LOGIN_FAIL_THREE_TIMES("10007", "登录密码错误，请重新确认！"),
    OLD_PWD_ERROR("10008", "旧密码不正确"),
    UPDATE_FAIL("20001", "上传失败"),
    FILE_TOO_BIG("20002", "文件过大"),
    /**考勤相关**/
    ATTENDANCE_SIGNED("20003", "已超过今日可签到时间"),
    /**建议书相关**/
    CREATE_PROPOSAL_ERROR("5001", "创建建议书失败"),
    MAKE_PROPOSAL_ERROR("5020", "制作建议书失败"),
    UPDATE_CUSTOMER_ERROR("5002", "投被保人更新失败"),
    LOAD_PROPOSAL_ERROR("5003", "加载建议书失败"),
    SAVE_PROPOSAL_ERROR("5004", "保存建议书失败"),
    DELETE_PROPOSAL_ERROR("5005", "删除建议书失败"),
    LIST_PRODUCT_ERROR("5006", "获取主险列表失败"),
    SET_PRODUCT_ERROR("5007", "保费计算有误"),
    VIEW_PRODUCT_ERROR("5008", "获取险种配置失败"),
    REMOVE_PRODUCT_ERROR("5009", "删除产品失败"),
    VIEW_ERROR("5010", "保费计算有误"),
    LOAD_PLAN_ERROR("5012", "加载计划书失败"),
    SAVE_PLAN_ERROR("5013", "保存计划书失败"),
    SHOW_BENEFIT_ERROR("5014", "获取利益演示失败"),
    RULE_ERROR("5015", "规则校验"),
    GET_RULE_ERROR("5016", "获取规则校验失败"),
    APPLICANT_ERROR("5017", "投保人录入不完整"),
    INSURANT_ERROR("5018", "被保人录入不完整"),
    COPY_PROPOSAL_ERROR("5019", "复制建议书失败"),
    UPDATE_PROPOSAL_ERROR("5020", "修改建议书失败"),

    /**投保相关**/
    PRESAVE_BENEFICTARY_ERROR("6001", "受益人预保存失败"),
    UPDATE_BENEFICTARY_ERROR("6002", "受益人添加/修改失败"),
    DELETE_BENEFICTARY_ERROR("6003", "受益人删除失败"),
    DETAIL_BENEFICTARY_ERROR("6004", "查看受益人失败"),
    SELECT_BENEFICTARY_ERROR("6005", "获取受益人选项失败"),
    BENEFICTARY_SORT_ERROR("6006", "受益人顺序无效"),
    BENEFICTARY_RADIO_ERROR("6007", "请确保同一顺位的受益人的受益比例之和为100%"),
    NO_APPILCANT_INFO("6008", "缺少投保人信息"),
    QUERYLIST_BENEFICTARY_ERROR("6009", "查看受益人失败"),

    /**核心接口**/
    ONS_SEND_FAIL("30001", "消息发送失败"),
    ONS_PROCESS_FAIL("30002", "消息处理失败"),
    TASK_FAIL("30003", "任务执行失败"),

    /**排行榜相关**/
    RANKING_NO_RANKING("40001","暂无排行数据"),

    /**积分系统***/
    POINTS_SIGN_ERROR("50001","数字签名错误"),
    POINTS_REQUEST_REPETITION("50002","请求重复"),
    POINTS_NO_ACCOUNT("50003","未查到帐户"),
    POINTS_NO_EVENT("50004","未查到事件"),
    POINTS_EVENT_NUM_LIMIT("50005","事件数被限制"),
    POINTS_EVENT_RULE_LIMIT("50006","达到规则限制"),
    POINTS_EVENT_ID_REPEAT("50007"," 事件Id重复"),

    /**工作日志**/
    NOTE_CREATE_ERROR("7001","创建工作日志失败"),
    NOTE_UPDATE_ERROR("7002","更新工作日志失败"),
    NOTE_NON_EXISTENT("7003","此工作日志不存在"),
    NOTE_DETAIL_ERROR("7004","获取单个日志详细信息失败"),
    NOTE_PERIOD_ERROR("7005","获取时间段内日志列表失败"),
    NOTE_SEARCH_ERROR("7006","日志检索失败"),


    /**任务中心**/
    MISSION_QUERY_ERROR("2000","任务中心查询错误"),
    MISSION_ACTIVE_ERROR("2001","活跃度查询错误"),
    MISSION_CHANGE_ERROR("2002","活跃度兑换错误"),
    MISSION_DRAW_ERROR("2003","任务奖励领取错误"),
    MISSION_INVOKE_ERROR("2004","执行任务出现错误"),
    MISSION_DRAW_FAILED("2005","奖励领取失败")
    ;

    private String errorCode;
    private String errorMsg;

    private ErrorCode(String errorCode, String errorMsg) {
        this.errorCode = errorCode;
        this.errorMsg = errorMsg;
    }

    public String getErrorCode() {
        return errorCode;
    }

    public void setErrorCode(String errorCode) {
        this.errorCode = errorCode;
    }

    public String getErrorMsg() {
        return errorMsg;
    }

    public void setErrorMsg(String errorMsg) {
        this.errorMsg = errorMsg;
    }

}
